<%@ page contentType="text/html;charset=UTF-8" language="java" %>
<%@ taglib prefix="s" uri="/struts-tags" %>


<script type="text/javascript" src="js/jquery.itextclear.js"></script>
<script type="text/javascript">
    $(document).ready(function() {
        $('input[type=text], input[type=password], input[type=url], input[type=email], input[type=number], textarea', '.form').iTextClear();
    });
</script>
<!-- jQplot CSS -->

<link rel="stylesheet" media="screen" href="${ctx}/css/Tree.css"/>
<!-- jQplot CSS END -->

<!-- DATATABLES CSS -->
<link rel="stylesheet" media="screen" href="lib/datatables/css/vpad.css"/>
<script type="text/javascript" src="lib/datatables/js/jquery.dataTables.js"></script>
<!-- DATATABLES CSS END -->

<h1 class="page-title">审核组织架构</h1>


<div id="demo" class="clearfix">
    <table class="display" id="example">
        <thead>
        <tr>
            <th>机构名称</th>
            <th>组织等级</th>
            <th>工号代码</th>
            <th>创建时间</th>
            <th>审核状态</th>
        </tr>
        </thead>
        <tbody>
        <s:iterator value="#request.organizations" var="c_o" status="sta">
            <s:if test="#sta.even"> <tr class="gradeA"> </s:if><s:else><tr class="gradeC"></s:else>
            <td>${c_o.fullName}</td>
            <td>${c_o.level.name}</td>
            <td>${c_o.employeeNo}</td>
            <td><s:date name="#c_o.create_date" format="yyyy-MM-dd HH:mm"/></td>
            <td><a class="button" href="#organization/audit_detail.xhtml?organizationId=${c_o.id}&t=<%=new java.util.Date().getTime()%>">
                <span style="background:url(${ctx}/images/img/script_error.png)" class="icon">&nbsp;</span>${c_o.status.name}
            </a>
            </td>
            </tr>
        </s:iterator>
        </tbody>
    </table>
</div>

<p><%@ include file="/WEB-INF/pages/common/main_orgtab_pager.jsp"%></p>

<div class="clear"></div>

<script type="text/javascript">
    var currentTabOrgId = ${organizationId};
    var currentSelOrgId = ${organizationId};
    function loadListContent(url, topId) {
        var data = {"organizationId":topId, "dutyId":$("#duty_sel_" + currentTabOrgId).val()};
        $.ajax(url, {
            type: "POST",
            data:{"organizationId":topId},
            dataType:"html",
            cache:false,
            success:function(a) {
                var obj = $("#list_content_" + topId);
                obj.html("");
                obj.append(a);
            },
            complete:function() {
            }
        });
    }
</script>

    
